package cn.iocoder.yudao.module.erp.controller.admin.report.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.math.BigDecimal;
import java.util.List;

/**
 * 客户交易分析响应 VO
 */
@Schema(description = "管理后台 - 客户交易分析响应 VO")
@Data
public class ErpCustomerTransactionRespVO {

    @Schema(description = "客户编号", requiredMode = Schema.RequiredMode.REQUIRED)
    private Long customerId;

    @Schema(description = "客户名称", requiredMode = Schema.RequiredMode.REQUIRED)
    private String customerName;

    @Schema(description = "累计购买次数", requiredMode = Schema.RequiredMode.REQUIRED)
    private Integer purchaseCount;

    @Schema(description = "累计购买金额(元)", requiredMode = Schema.RequiredMode.REQUIRED)
    private BigDecimal purchaseAmount;

    @Schema(description = "累计回收次数", requiredMode = Schema.RequiredMode.REQUIRED)
    private Integer recycleCount;

    @Schema(description = "累计回收金额(元)", requiredMode = Schema.RequiredMode.REQUIRED)
    private BigDecimal recycleAmount;

    @Schema(description = "累计兑换次数", requiredMode = Schema.RequiredMode.REQUIRED)
    private Integer exchangeCount;

    @Schema(description = "交易金属详情列表", requiredMode = Schema.RequiredMode.REQUIRED)
    private List<CustomerMetalDetailVO> metalDetails;

    /**
     * 客户金属交易详情 VO
     */
    @Schema(description = "客户金属交易详情")
    @Data
    public static class CustomerMetalDetailVO {

        @Schema(description = "贵金属类型", requiredMode = Schema.RequiredMode.REQUIRED)
        private Integer metalType;

        @Schema(description = "贵金属类型名称", requiredMode = Schema.RequiredMode.REQUIRED)
        private String metalTypeName;

        @Schema(description = "纯度", requiredMode = Schema.RequiredMode.REQUIRED)
        private Integer purity;

        @Schema(description = "购买总量(克)", requiredMode = Schema.RequiredMode.REQUIRED)
        private BigDecimal purchaseQuantity;

        @Schema(description = "购买总额(元)", requiredMode = Schema.RequiredMode.REQUIRED)
        private BigDecimal purchaseAmount;

        @Schema(description = "回收总量(克)", requiredMode = Schema.RequiredMode.REQUIRED)
        private BigDecimal recycleQuantity;

        @Schema(description = "回收总额(元)", requiredMode = Schema.RequiredMode.REQUIRED)
        private BigDecimal recycleAmount;

        @Schema(description = "兑换旧料总量(克)", requiredMode = Schema.RequiredMode.REQUIRED)
        private BigDecimal exchangeOldQuantity;

        @Schema(description = "兑换新品总量(克)", requiredMode = Schema.RequiredMode.REQUIRED)
        private BigDecimal exchangeNewQuantity;
    }
} 